<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    // match 总字符串中提取内容
    const str = 'abc 333 de 三543f 34 nba 87'
    
    // const reg = /\d/
    // const reg = /\d/g
    // const reg = /\d\d/g
    // const reg = /\d\d\d/g
    const reg = /\d+/g

    alert(str.match(reg))
    
  </script>
</body>
</html>